<?php
	require_once( 'core_DataBaseConnect.php' );
	require_once( 'core_ErrorCode.php' );
	require_once( 'core_Response.php' );
	require_once( 'core_FileManager.php' );
	require_once( 'dao_MemberDAO.php' );
	require_once( 'dao_ModelDAO.php' );
	require_once( '_configs.php' );
	
	function func( $con, $post, $returnType )
	{
		$model_code			= $post[ 'modelCode' ];
		
		$response = array();
		
		// 직책 조회
		$result = ModelDAO::selectModelDuty( $con, $model_code );
		$response[ 'duty' ] = array();
		while( $fetch = DataBaseConnect::fetch_assoc( $result ) )
		{
			array_push( $response[ 'duty' ], DataBaseConnect::fetchSerialize( $fetch, array( 'SEQ', 'START', 'END', 'P_CODE', 'R_CODE', 'D_CODE', 'MEMO', 'COM_CODE' ) ) );
		}
		
		return Response::SUCCESS( $response, $returnType );
	}
?>